In one conventional approach to mirroring, a computer system writes data to a first disk and copies the data to a second disk. For example, the computer system can write data to a local disk and subsequently write data to a disk of an external data storage system. In particular, when the computer system makes a change to the original data stored on the local disk of the computer system, such as by a change data command to write new data to the local disk, the computer system sends the change data command to the external data storage system to update the mirror copy of the data. Thus, the computer system maintains the data on the mirror copy as a mirror or exact duplicate of the original data stored on the local disk of the computer system. The mirror copy provides a fault tolerant copy of the original data. If there is a failure of the original local disk and loss of the original data, the computer system disk can use the mirror disk on the external data storage system as a replacement of the original disk.
In another conventional approach to mirroring data (i.e., mirroring on the same data storage system), a host computer system stores data (i.e., original or master version of the data) on an external data storage system connected to the host computer system (e.g., connected by a channel connection), such as on a disk on the data storage system. The data storage system includes processing circuitry that creates a mirror copy of the data within the same data storage system, for example, by copying the original data from one disk to a mirror copy on another (e.g., mirror) disk in the same data storage system. As the processing circuitry of the data storage system changes data on the original version of the data, the processing circuitry makes the same changes to the data on the mirror copy. If there is a failure of the original disk, the host computer system can still access the other disk having the mirror copy of the data by communicating with the processing circuitry.
In addition, in the approach of mirroring on the same data storage system, the data storage system can then stop or quiesce the process of updating the mirror copy, thus performing a split of the mirror copy from the original version of the data. The data storage system can then make a further additional copy of the mirror copy. After making this additional copy, the data storage system can end the split by updating the mirror copy with any changes made to the original version of the data while the split was in effect so that the mirror copy becomes an up-to-date mirror of the original data. The additional copy of data made during the split can serve as an additional mirror copy available for restoration operations, or be made available for other purposes.
The conventional approaches described above have a number of deficiencies when mirroring data. In the approach of mirroring from a local disk to an external data storage system, the host computer performs the mirroring for the purpose of fault tolerance, so that the host computer can access the mirror copy if the local disk fails. In such a case, if the host computer wishes to have the data available on a local disk (e.g., if the failed disk is replaced with a new disk), the host computer must typically perform a lengthy process of copying all of the data from the mirror copy on the external data storage system to the local disk. In addition, this approach is not adapted to enable the host computer to perform other kinds of operations on the mirror copy, such as making an additional copy of the mirror copy.
In the conventional approach of mirroring on the same data storage system, both the original version of the data and the mirror copy reside on the same data storage system. If a failure of the data storage system occurs, or of the connection between the host computer and the data storage system, then the host computer loses access to both copies of the data. In addition, the host computer views only the original version of the data on the data storage system and does not have a direct access to the mirror copy of the data, unless the original disk fails and the processing circuitry of the data storage system provides the host computer with access to the mirror copy in place of the original version. Generally, the host computer cannot directly invoke operations, such as splitting and making additional copies, on the mirror copy of the data. For example, the host computer cannot mirror a local disk to a mirror copy in an external data storage system and then split the local disk from the mirror copy. Such operations must be initiated and performed by the processing circuitry of the data storage system on an original version of data and mirror copy both stored on the data storage system.
In contrast, in the approach of the invention, the host computer can direct operations on a remote mirror or synchronous copy of a data set, such as generating a duplicate copy, while retaining the original version of the data set resident on the host computer (or a data storage device closely coupled to the host computer). The host computer can direct that the synchronous copy that resides on a data storage assembly be split from the original version, and a duplicate copy be made from the mirror (e.g., synchronous copy). Thus, the host computer can make a duplicate copy available for its own use, as an additional mirror, for backup purposes, or for other purposes, such as analysis of the data in the duplicate copy by another host computer. In the case of a disk, power, or other failure, the host computer has the advantage of accessing the data in its original version, in the mirror copy, or in an additional copy previously made during a split operation depending on which version or copy is available.
In one embodiment, the invention is directed to a host computer for generating a duplicate copy of a data set on a data storage assembly in communication with the host computer. The host computer includes a memory that stores a data manager application, a storage device that stores a data set, an input/output controller in communication with the memory and the storage device, and a processor in communication with the memory, the storage device, and the input/output controller. The processor, when operating in accordance with the data manager application, forms a data manager, which establishes a synchronous relationship between the data set and a synchronous copy of the data set splits the data set from the synchronous copy of the data set to terminate the synchronous relationship between the data set and the synchronous copy of the data set, and copies the synchronous copy of the data set to generate the duplicate copy of the data set. The synchronous copy is stored on the data storage assembly. Thus the data manager can control, from the host computer, a split of the data set and the synchronous copy, and the generation of the duplicate copy of data set from the synchronous copy.
In another embodiment, the data manager application further configures the processor to re-establish the synchronous relationship between the data set and the synchronous copy of the data set, after copying the synchronous copy of the data set. The data manager can re-establish the synchronous relationship to update the data in the data set to match the data in the synchronous copy.
In another embodiment, the data manager application further configures the processor to set up a track table on the data storage assembly that provides status entries for tracks for the synchronous copy of the data set. The data manager can use the data storage assembly track table to determine which tracks for the synchronous copy have changed data, for example, if the data set is unavailable and the data manager is using the synchronous copy as the master version of the data set. Thus, during an incremental restoration of the data set the data manager can use the data storage assembly track table to determine which tracks of the synchronous copy must be copied to the data set to restore the data set so that the data in the data set matches the data in the synchronous copy.
In a further embodiment, the data manager application further configures the processor to set each status entry in the data storage assembly track table to an invalid status, and, while copying data from the data set to each respective track of the synchronous copy of the data set, to set each status entry for each respective track in the data storage assembly track table to a valid status. Thus, during an establishment operation when first establishing the synchronous copy, the data manager can use the data storage assembly track table to determine which tracks on the synchronous copy have been copied from the data set and, if an interruption occurs, which tracks on the synchronous copy still need to be copied from the data set.
In another embodiment, the data manager application further configures the processor to access, in response to an unavailability of the data set, a specific track in the synchronous copy of the data set to change data in the specific track and setting a respective status entry for the specific track in the data storage assembly track table to indicate a change status for the specific track. Thus, if the data set is unavailable due to a mechanical or other problem, the data manager can use the synchronous copy as the master version of the data set, while using the track table on the data storage assembly to indicate which tracks on the synchronous copy have changed after the data set becoming unavailable.
In another embodiment, the data manager application further configures the processor to set up a host track table on the host computer that provides status entries for tracks for the data set. Thus the data manager can set up a track table on the host computer for the data set to list changes in data in the data set.
In an additional embodiment, the data manager application further configures the processor to copy changed tracks identified by the status entries in the host track table from the data set to the synchronous copy of the data set to re-establish the synchronous relationship between the data set and the synchronous copy of the data set. Thus the data manager can use the track table on the host computer to determine which tracks have changed data and must be copied to the synchronous copy to insure that the data in the synchronous copy is the same as the data in the data set.
In another embodiment, the data manager application further configures the processor to update the data set based on pending changes to the data set and to quiesce the data set. Thus, in anticipation of an establishment or split operation, the data manager can update the data set and cease to make any additional changes for a period of time (e.g., while a duplicate copy is made).
In a further embodiment, the data manager application further configures the processor to apply the pending changes maintained in an application queue to the data set. Thus, the data manager may access an application (e.g., airline reservations application) performing on the host computer to flush any pending data changes from the queue and apply them to the data set in anticipation of an establishment or split operation requiring that changes to the data set be suspended for a period of time.
In some embodiments, the techniques of the invention are implemented primarily by computer software. The computer program logic embodiments, which are essentially software, when executed on one or more hardware processors in one or more hardware computing systems cause the processors to perform the techniques outlined above. In other words, these embodiments of the invention are generally manufactured as a computer program stored on a disk, memory, card, or other such media that can be loaded directly into a computer, or downloaded over a network into a computer, to make the device perform according to the operations of the invention. In one embodiment, the techniques of the invention are implemented in hardware circuitry, such as an integrated circuit (IC) or application specific integrated circuit (ASIC).
The techniques of the invention may be employed in computer systems, data storage systems and components of such systems, as well as other computer-related systems and devices, such as those manufactured by EMC Corporation of Hopkinton, Mass.